<?php

namespace app\api\controller\v1\member;


use app\api\controller\v1\Member;
use think\Db;

/**
 * 广告图
 * Class Ad
 * @package app\api\controller\v1\member
 */
class Ad extends Member
{
    /**
     * 指定数据库
     * @var string
     */
    private $table = 'Ad';

    /**
     * 获取轮播图列表
     * @throws \think\db\exception\DataNotFoundException
     * @throws \think\db\exception\ModelNotFoundException
     * @throws \think\exception\DbException
     */
    public function index()
    {
        $list = Db::name($this->table)->where(['is_deleted'=>0,'status'=>1])->select();
        $this->success('轮播图获取成功',$list);
    }
}